using System;

namespace Genko.Model.Schema
{
    public class ClassType : SchemaMember
	{
        private string _base = null;

		protected internal ClassType()
		{

		}
		
		protected internal ClassType(MetaModel metaModel) : base(metaModel)
		{
			
		}

        [MemberAttribute]
        public virtual string Base
        {
            get { return this._base; }
            protected internal set { this._base = value; }
        }

		[MemberAttribute]
		public override string MemberID
		{
			get
			{
				return base.MemberID;
			}
		}

        protected virtual ObjectMember CreateInstance(Type memberType)
        {
            ObjectMember obj = (ObjectMember)this.Scheme.CreateMember(memberType);
            obj.type = this;
            return obj;
        }

		public virtual ObjectMember CreateInstance()
		{
			return this.CreateInstance(typeof(ObjectMember));
		}
	}
}
